import Vue from 'vue';
import Router from 'vue-router';
import Registerorlogin from '../views/Register or login';
import Register from '../views/Register';
import Login from '../views/Login';
import Kit from '../views/Kit';
import Common from '../views/Common';
import Exist from '../views/Exist';
import Toremember from '@/views/Toremember';
import Information from '@/views/Information';
import Mypage from '@/views/Mypage';
import Afterattention from '@/views/Afterattention';
import Bestitem from '@/views/Bestitem';
import Best from '@/views/Best';
import Nutrition from '@/views/Nutrition';
import Classify from '@/views/Classify';
import Discuss from '@/views/Discuss';
import Waitrecriving from '@/views/Waitrecriving';
import Myorder from '@/views/Myorder';
import Cart from '@/views/Cart';
import Allachievement from '@/views/Allachievement';
import Coupons from "@/views/Coupons";
import Imgdetails from "@/views/Imgdetails";
import Loadimg from "@/views/Loadimg";
import Canyoueat from "@/views/Canyoueat";
import Makealbum from "@/views/Makealbum";
import Member from "@/views/Member";
import Myfavorite from '@/views/Myfavorite';
import Pregnancy from '@/views/Pregnancy';
import Products from '@/views/Products';
import Recipe from '@/views/Recipe';
import Thechatpage from '@/views/Thechatpage';
import Fooddetails from "@/views/Fooddetails";
import Achievement from "@/views/Achievement";
import Chatinteractionzj from "@/views/Chatinteractionzj";
import Buyinterface from "@/views/Buyinterface";
import Productdetails from "@/views/Productdetails";
import Shoppingcart from "@/views/Shoppingcart";
import Review from "@/views/Review";
import Cloudphoto from "@/views/Cloudphoto";
import IFavorite from "@/views/IFavorite";
import Growhredcord from "@/views/Growhredcord";
import FirsterTrimester from "@/views/FirsterTrimester";
import Answer from "@/views/Answer";
import CleanPage from "@/views/CleanPage";
import Encyclopedia from "@/views/Encyclopedia";
import Babies from "@/views/Babies";
Vue.use(Router);

export default new Router({
  routes: [
    {
      path: '/registerorlogin',
      name: 'Registerorlogin',
      component: Registerorlogin
    },
    {
      path:'/register',
      name:'Register',
      component:Register
    },
    {
      path:'/login',
      name:'Login',
      component:Login
    },
    {
      path:'/',
      name:'Common',
      component:Common,
      redirect:'/kit',
      children:[
        {
          path:'/kit',
          component:Kit,
          
        },
        {
          path:'/review',
          component:Review
        },
        {
          path:'/nutrition',
          name:'Nutrition',
          component:Nutrition,
          children:[
            {
              path:'/nutrition',
              component:Classify
            }
          ]
        },
        {
          path:'/exist',
          component:Exist,
        },
        {
          path:'/toremember',
          component:Toremember
        },
        {
          path:'/information',
          component:Information,
          children:[
            {
              path:'/information',
              name:'Chatinteractionzj',
              component:Chatinteractionzj
            }
          ]
        },
        {
          path:'/mypage',
          component:Mypage,
          
        },
        {
          path:'/afterattention',
          component:Afterattention,
          children:[
            {
              path:'/afterattention',
              component:Discuss
            }
          ]
        }

      ]
    },
    {
      path:'/bestitem',
      name:'Bestitem',
      component:Bestitem,
      children:[
        {
          path:'/bestitem',
          name:'Best',
          component:Best,
        }
      ]
    },
    {
      path:'/myorder',
      component:Myorder,
    },
    {
      path:'/Waitrecriving',
      component:Waitrecriving
    },
    {
      path:'/cart',
      component:Cart,
      children:[
        {
          path:'/cart',
          name:'Best',
          component:Best,
        }
      ]
    },
    {
      path:'/allachievement',
      name:'Allachievement',
      component:Allachievement
    },
    {
      path:'/coupons',
      name:'Coupons',
      component:Coupons
    },
    {
      path:'/imgdetails',
      name:'Imgdetails',
      component:Imgdetails
    },
    {
      path:'/loadimg',
      name:'Loadimg',
      component:Loadimg
    },
    {
      path:'/makealbum',
      name:'Makealbum',
      component:Makealbum
    },
    {
      path:'/canyoueat',
      name:'Canyoueat',
      component:Canyoueat
    },
    {
      path:'/member',
      name:'Member',
      component:Member
    },
    {
      path:'/myfavorite',
      name:'Myfavorite',
      component:Myfavorite
    },
    {
      path:'/pregnancy',
      name:'Pregnancy',
      component:Pregnancy,
      children:[
        {
          path:'/pregnancy',
          component:Discuss
        }
      ]
    },
    {
      path:'/products',
      name:'Products',
      component:Products
    },
    {
      path:'/recipe',
      name:'Recipe',
      component:Recipe
    },
    {
      path:'/thechatpage',
      name:'Thechatpage',
      component:Thechatpage
     
    },
    {
      path:'/fooddetails',
      name:'Fooddetails',
      component:Fooddetails
    },
    {
      path:'/achievement',
      name:"Achievement",
      component:Achievement
    },
    {
      path:'/buyinterface',
      name:'Buyinterface',
      component:Buyinterface
    },
    {
      path:'/productdetails',
      name:'Productdetails',
      component:Productdetails
    },
    {
      path:'/shoppingcart',
      name:'Shoppingcart',
      component:Shoppingcart
    },
    {
      path:'/cloudphoto',
      name:'Cloudphoto',
      component:Cloudphoto,
      children:[
        {
          path:'/cloudphoto',
          name:'Imgdetails',
          component:Imgdetails
        }
      ]
    },
    {
      path:'/ifavorite',
      name:'IFavorite',
      component:IFavorite
    },{
      path:'/growhredcord',
      name:'Growhredcord',
      component:Growhredcord
    },{
      path:'/firsterTrimester',
      name:'FirsterTrimester',
      component:FirsterTrimester
    },
    {
      path:'/answer',
      name:'Answer',
      component:Answer
    },
    {
      path:'/cleanPage',
      name:'CleanPage',
      component:CleanPage
    },
    {
      path:'/encyclopedia',
      name:'Encyclopedia',
      component:Encyclopedia
    },
    {
      path:'/babies',
      name:'Babies',
      component:Babies
    }

    

   

  ]
})
